import http from '@/utils/request'
/**
 * 获取联想建议（自动补全）
 * @param {*} q
 * @returns
 */
export const reqGetSuggestions = (q) => http({
  url: '/v1_0/suggestion',
  method: 'get',
  params: {
    q
  }
})

/**
 * 搜索结果接口
 * @param {*} q 搜索关键字
 * @param {*} page 搜索页码
 */
export const reqGetSearch = (q, page) => {
  return http({
    method: 'get',
    url: '/v1_0/search',
    params: {
      q,
      page
    //   per_page
    }
  })
}
